{*
  Object Pascal simple measurement unit manipulation routines
  @Author  Maciej Zagozda (1998-2008)
  @Licence Microsoft Reciprocal License (Ms-RL)
  @Website http://www.codeplex.com/intelitechdelphirtns/
  @Version 2008/04/20 Added documentation support
}

unit UnitRoutines;

interface

uses
  Classes,
  Dialogs,
  Forms,
  Messages,
  SysUtils,
  Windows;

type
  TDeviceType = (dtScreen, dtPrinter);

function GetPixelsPerCentimeter( DeviceType: TDeviceType ): Integer;

implementation

function GetPixelsPerCentimeter( DeviceType: TDeviceType ): Integer;
begin
  if DeviceType = dtScreen then
  begin
    Result := Trunc( Screen.PixelsPerInch / 2.54 );
  end;//if
end;

end.
